From 378f89399a2d4a2831e3274fe98ff97e6fbdf96c Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Sat, 5 Jun 1993 17:31:54 +0000 Subject: [PATCH] (Fx_popup_menu): Error if we don't get a window or a frame somehow. --- src/xmenu.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/xmenu.c b/src/xmenu.c index a5b69946b7a..1f70766426d 100644 --- a/src/xmenu.c +++ b/src/xmenu.c @@ -163,6 +163,10 @@ With this form of menu, the return value is VALUE from the chosen item.") XMenu_xpos = FONT_WIDTH (f->display.x->font) * XWINDOW (window)->left; XMenu_ypos = FONT_HEIGHT (f->display.x->font) * XWINDOW (window)->top; } + else + /* ??? Not really clean; should be CHECK_WINDOW_OR_FRAME, + but I don't want to make one now. */ + CHECK_WINDOW (window, 0); XMenu_xpos += FONT_WIDTH (f->display.x->font) * XINT (x); XMenu_ypos += FONT_HEIGHT (f->display.x->font) * XINT (y); -- 2.30.2